<template>
    <input type="text" v-model.lazy="searchName" >
    <select>
        <option v-for="item in countryData" :key="item._id">
            {{ item.name }}
        </option>
    </select>
</template>

<script setup>
import { ref, watch } from 'vue';
const props = defineProps(['countryData']);
const emit = defineEmits(['searchData'])

const searchName = ref('')
watch(()=>searchName.value,()=>{
    emit('searchData',searchName.value)
    
})
</script>

<style scoped>

</style>